import java.util.*;
import java.awt.Point;

public interface ServerInterface extends java.rmi.Remote{
	
	public void slaveMode(String url, int port) throws java.rmi.RemoteException;
	public void masterMode(int port) throws java.rmi.RemoteException;
	public void addSlave(String uid, ServerInterface slave) throws java.rmi.RemoteException;
	public void removeSlave(String uid) throws java.rmi.RemoteException;
	public List<ServerInterface> getClients() throws java.rmi.RemoteException;
	
	public void updateSlave(List<CardData> cds)throws java.rmi.RemoteException;
	public void receiveUpdate(List<CardData> cds) throws java.rmi.RemoteException;
	
	//new shit
	public void masterFlip(String uid, int[] ids) throws java.rmi.RemoteException;
	public void slaveFlip(int[] ids) throws java.rmi.RemoteException;
	public void masterMoveBy(String uid, int[] ids, Point point) throws java.rmi.RemoteException;
	public void slaveMoveBy(int[] ids, Point point) throws java.rmi.RemoteException;
	
	//METHODS FROM PLAYERLISTENER
	/*
	public Table getTable(Player... p)throws java.rmi.RemoteException;
	public void hold(Player... p)throws java.rmi.RemoteException;
	public void release(Player... p)throws java.rmi.RemoteException;
	public void select(Set<Card> cards, Player... p)throws java.rmi.RemoteException;
	public void dropSelection(Set<Card> cards, Player... p)throws java.rmi.RemoteException;
	public void moveBy(Point point, Player... p)throws java.rmi.RemoteException;
	public void flip(Player... p)throws java.rmi.RemoteException;*/
	
	//public Table getTable()throws java.rmi.RemoteException;
	public void hold()throws java.rmi.RemoteException;
	public void release()throws java.rmi.RemoteException;
	public void select(Set<Card> cards)throws java.rmi.RemoteException;
	public void dropSelection(Set<Card> cards)throws java.rmi.RemoteException;
	public void moveBy(Point point)throws java.rmi.RemoteException;
	public void flip()throws java.rmi.RemoteException;
}
